version: "3.8"

services:
  prometheus:
    image: prom/prometheus
    container_name: prometheus
    restart: unless-stopped
    environment:
      TZ: "Europe/Moscow"
    ports:
      - 9090:9090
    volumes:
      - ./prometheus_data/prometheus.yml:/etc/prometheus/prometheus.yml
    command:
      - "--config.file=/etc/prometheus/prometheus.yml"

  grafana:
    image: grafana/grafana
    container_name: grafana
    restart: unless-stopped
    environment:
      TZ: "Europe/Moscow"
    ports:
      - 3000:3000
    volumes:
      - ./grafana/dashboards/:/var/lib/grafana/dashboards/
      - ./grafana/provisioning/:/etc/grafana/provisioning/
    depends_on:
      - prometheus
